﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace KQ.DCMMP.Common
{
    public static class DefaultDataTypes
    {
        public const string Byte = "System.Byte[]";
        public const string String = "System.String";
        public const string Int32 = "System.Int32";
        public const string Int16 = "System.Int16";
        public const string Double = "System.Double";
        public const string Decimal = "System.Decimal";
        public const string DateTime = "System.DateTime";
        public const string Boolean = "System.Boolean";

        public static bool IsByte(string extensionType)
        {
            return string.Equals(extensionType, Byte, StringComparison.OrdinalIgnoreCase);
        }

        public static bool IsString(string extensionType)
        {
            return string.Equals(extensionType, String, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsInt32(string extensionType)
        {
            return string.Equals(extensionType, Int32, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsInt16(string extensionType)
        {
            return string.Equals(extensionType, Int16, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDouble(string extensionType)
        {
            return string.Equals(extensionType, Double, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDecimal(string extensionType)
        {
            return string.Equals(extensionType, Decimal, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsDateTime(string extensionType)
        {
            return string.Equals(extensionType, DateTime, StringComparison.OrdinalIgnoreCase);
        }
        public static bool IsBoolean(string extensionType)
        {
            return string.Equals(extensionType, Boolean, StringComparison.OrdinalIgnoreCase);
        }
    }
}
